# -*- coding: utf-8 -*-

###########################################################################
## Python code generated with wxFormBuilder (version 3.10.1-0-g8feb16b3)
## http://www.wxformbuilder.org/
##
## PLEASE DO *NOT* EDIT THIS FILE!
###########################################################################

import wx
import wx.xrc


###########################################################################
## Class SocketClientPanel
###########################################################################

class SocketClientPanel(wx.Panel):

    def __init__(self, parent, id=wx.ID_ANY, pos=wx.DefaultPosition, size=wx.Size(1000, 400), style=wx.TAB_TRAVERSAL,
                 name=wx.EmptyString):
        wx.Panel.__init__(self, parent, id=id, pos=pos, size=size, style=style, name=name)

        bSizer31 = wx.BoxSizer(wx.HORIZONTAL)

        bSizer31.SetMinSize(wx.Size(1000, 400))
        bSizer32 = wx.BoxSizer(wx.VERTICAL)

        bSizer32.SetMinSize(wx.Size(300, -1))
        bSizer40 = wx.BoxSizer(wx.HORIZONTAL)

        self.clientRadioBtn = wx.RadioButton(self, wx.ID_ANY, u"客户端", wx.DefaultPosition, wx.DefaultSize, 0)
        self.clientRadioBtn.SetValue(True)
        bSizer40.Add(self.clientRadioBtn, 0, wx.ALL, 5)

        self.serverRadioBtn = wx.RadioButton(self, wx.ID_ANY, u"服务端", wx.DefaultPosition, wx.DefaultSize, 0)
        bSizer40.Add(self.serverRadioBtn, 0, wx.ALL, 5)

        bSizer32.Add(bSizer40, 0, wx.EXPAND, 5)

        layout_ip = wx.BoxSizer(wx.HORIZONTAL)

        self.m_staticText20 = wx.StaticText(self, wx.ID_ANY, u"IP", wx.DefaultPosition, wx.DefaultSize, 0)
        self.m_staticText20.Wrap(-1)

        layout_ip.Add(self.m_staticText20, 0, wx.ALL, 5)

        self.edit_ip = wx.TextCtrl(self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0)
        layout_ip.Add(self.edit_ip, 1, wx.ALL, 5)

        bSizer32.Add(layout_ip, 0, wx.EXPAND, 5)

        bSizer35 = wx.BoxSizer(wx.HORIZONTAL)

        self.staticText21 = wx.StaticText(self, wx.ID_ANY, u"端口", wx.DefaultPosition, wx.DefaultSize, 0)
        self.staticText21.Wrap(-1)

        bSizer35.Add(self.staticText21, 0, wx.ALL, 5)

        self.edit_port = wx.TextCtrl(self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0)
        bSizer35.Add(self.edit_port, 1, wx.ALL, 5)

        bSizer32.Add(bSizer35, 0, wx.EXPAND, 5)

        bSizer37 = wx.BoxSizer(wx.HORIZONTAL)

        self.btn_open = wx.Button(self, wx.ID_ANY, u"打开", wx.DefaultPosition, wx.DefaultSize, 0)
        bSizer37.Add(self.btn_open, 0, wx.ALL, 5)

        bSizer32.Add(bSizer37, 0, wx.EXPAND, 5)

        bSizer31.Add(bSizer32, 0, wx.EXPAND, 5)

        bSizer33 = wx.BoxSizer(wx.VERTICAL)

        self.m_staticText22 = wx.StaticText(self, wx.ID_ANY, u"接收信息", wx.DefaultPosition, wx.DefaultSize, 0)
        self.m_staticText22.Wrap(-1)

        bSizer33.Add(self.m_staticText22, 0, wx.ALL, 5)

        bSizer391 = wx.BoxSizer(wx.HORIZONTAL)

        self.edit_receive = wx.TextCtrl(self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.Size(400, 120),
                                        wx.TE_MULTILINE)
        bSizer391.Add(self.edit_receive, 0, wx.ALL, 5)

        self.m_button26 = wx.Button(self, wx.ID_ANY, u"清空", wx.DefaultPosition, wx.DefaultSize, 0)
        bSizer391.Add(self.m_button26, 0, wx.ALL, 5)

        bSizer33.Add(bSizer391, 1, wx.EXPAND, 5)

        self.m_staticText23 = wx.StaticText(self, wx.ID_ANY, u"发送信息", wx.DefaultPosition, wx.DefaultSize, 0)
        self.m_staticText23.Wrap(-1)

        bSizer33.Add(self.m_staticText23, 0, wx.ALL, 5)

        bSizer38 = wx.BoxSizer(wx.HORIZONTAL)

        self.edit_send = wx.TextCtrl(self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.Size(400, -1),
                                     wx.TE_MULTILINE)
        bSizer38.Add(self.edit_send, 0, wx.ALL | wx.EXPAND, 5)

        bSizer39 = wx.BoxSizer(wx.VERTICAL)

        self.btn_send = wx.Button(self, wx.ID_ANY, u"发送", wx.DefaultPosition, wx.DefaultSize, 0)
        bSizer39.Add(self.btn_send, 0, wx.ALL, 5)

        self.btn_clear = wx.Button(self, wx.ID_ANY, u"清空", wx.DefaultPosition, wx.DefaultSize, 0)
        bSizer39.Add(self.btn_clear, 0, wx.ALL, 5)

        bSizer38.Add(bSizer39, 1, wx.EXPAND, 5)

        bSizer33.Add(bSizer38, 1, wx.EXPAND, 5)

        self.m_staticText24 = wx.StaticText(self, wx.ID_ANY, u"日志输出", wx.DefaultPosition, wx.DefaultSize, 0)
        self.m_staticText24.Wrap(-1)

        bSizer33.Add(self.m_staticText24, 0, wx.ALL, 5)

        self.edit_log = wx.TextCtrl(self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize,
                                    wx.TE_MULTILINE)
        bSizer33.Add(self.edit_log, 1, wx.ALL | wx.EXPAND, 5)

        bSizer31.Add(bSizer33, 1, wx.EXPAND, 5)

        self.SetSizer(bSizer31)
        self.Layout()

        # Connect Events
        self.clientRadioBtn.Bind(wx.EVT_RADIOBUTTON, self.choose_client)
        self.serverRadioBtn.Bind(wx.EVT_RADIOBUTTON, self.choose_server)
        self.btn_open.Bind(wx.EVT_BUTTON, self.open)
        self.m_button26.Bind(wx.EVT_BUTTON, self.clear_receive_input)
        self.btn_send.Bind(wx.EVT_BUTTON, self.sendMessage)
        self.btn_clear.Bind(wx.EVT_BUTTON, self.clear_send_input)

    def __del__(self):
        pass

    # Virtual event handlers, override them in your derived class
    def choose_client(self, event):
        event.Skip()

    def choose_server(self, event):
        event.Skip()

    def open(self, event):
        event.Skip()

    def clear_receive_input(self, event):
        event.Skip()

    def sendMessage(self, event):
        event.Skip()

    def clear_send_input(self, event):
        event.Skip()
